Optimal. Leaf size=87 \[ \frac {3 \tanh ^{-1}(\cosh (c+d x))}{2 a d}+\frac {2 i \coth (c+d x)}{a d}-\frac {3 \coth (c+d x) \text {csch}(c+d x)}{2 a d}+\frac {\coth (c+d x) \text {csch}(c+d x)}{d (a+i a \sinh (c+d x))} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.10, antiderivative size = 87, normalized size of antiderivative = 1.00, number of steps
used = 6, number of rules used = 6, integrand size = 24, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.250, Rules used = {2847, 2827,
3853, 3855, 3852, 8} \begin {gather*} \frac {2 i \coth (c+d x)}{a d}+\frac {3 \tanh ^{-1}(\cosh (c+d x))}{2 a d}-\frac {3 \coth (c+d x) \text {csch}(c+d x)}{2 a d}+\frac {\coth (c+d x) \text {csch}(c+d x)}{d (a+i a \sinh (c+d x))} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 8
Rule 2827
Rule 2847
Rule 3852
Rule 3853
Rule 3855
Rubi steps
\begin {align*} \int \frac {\text {csch}^3(c+d x)}{a+i a \sinh (c+d x)} \, dx &=\frac {\coth (c+d x) \text {csch}(c+d x)}{d (a+i a \sinh (c+d x))}-\frac {\int \text {csch}^3(c+d x) (-3 a+2 i a \sinh (c+d x)) \, dx}{a^2}\\ &=\frac {\coth (c+d x) \text {csch}(c+d x)}{d (a+i a \sinh (c+d x))}-\frac {(2 i) \int \text {csch}^2(c+d x) \, dx}{a}+\frac {3 \int \text {csch}^3(c+d x) \, dx}{a}\\ &=-\frac {3 \coth (c+d x) \text {csch}(c+d x)}{2 a d}+\frac {\coth (c+d x) \text {csch}(c+d x)}{d (a+i a \sinh (c+d x))}-\frac {3 \int \text {csch}(c+d x) \, dx}{2 a}-\frac {2 \text {Subst}(\int 1 \, dx,x,-i \coth (c+d x))}{a d}\\ &=\frac {3 \tanh ^{-1}(\cosh (c+d x))}{2 a d}+\frac {2 i \coth (c+d x)}{a d}-\frac {3 \coth (c+d x) \text {csch}(c+d x)}{2 a d}+\frac {\coth (c+d x) \text {csch}(c+d x)}{d (a+i a \sinh (c+d x))}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 0.35, size = 90, normalized size = 1.03 \begin {gather*} \frac {4 i \text {csch}(2 (c+d x))-3 \text {sech}(c+d x)+3 \tanh ^{-1}\left (\sqrt {\cosh ^2(c+d x)}\right ) \sqrt {\cosh ^2(c+d x)} \text {sech}(c+d x)-\text {csch}^2(c+d x) \text {sech}(c+d x)+4 i \tanh (c+d x)}{2 a d} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A]
time = 1.17, size = 91, normalized size = 1.05
method | result | size |
derivativedivides | \(\frac {2 i \tanh \left (\frac {d x}{2}+\frac {c}{2}\right )+\frac {\left (\tanh ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{2}+\frac {8 i}{-i+\tanh \left (\frac {d x}{2}+\frac {c}{2}\right )}-\frac {1}{2 \tanh \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}}+\frac {2 i}{\tanh \left (\frac {d x}{2}+\frac {c}{2}\right )}-6 \ln \left (\tanh \left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{4 d a}\) | \(91\) |
default | \(\frac {2 i \tanh \left (\frac {d x}{2}+\frac {c}{2}\right )+\frac {\left (\tanh ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{2}+\frac {8 i}{-i+\tanh \left (\frac {d x}{2}+\frac {c}{2}\right )}-\frac {1}{2 \tanh \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}}+\frac {2 i}{\tanh \left (\frac {d x}{2}+\frac {c}{2}\right )}-6 \ln \left (\tanh \left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{4 d a}\) | \(91\) |
risch | \(-\frac {-3 i {\mathrm e}^{3 d x +3 c}-5 \,{\mathrm e}^{2 d x +2 c}+3 \,{\mathrm e}^{4 d x +4 c}+i {\mathrm e}^{d x +c}+4}{\left ({\mathrm e}^{2 d x +2 c}-1\right )^{2} \left ({\mathrm e}^{d x +c}-i\right ) a d}+\frac {3 \ln \left ({\mathrm e}^{d x +c}+1\right )}{2 d a}-\frac {3 \ln \left ({\mathrm e}^{d x +c}-1\right )}{2 d a}\) | \(113\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [A]
time = 0.27, size = 156, normalized size = 1.79 \begin {gather*} -\frac {-i \, e^{\left (-d x - c\right )} - 5 \, e^{\left (-2 \, d x - 2 \, c\right )} + 3 i \, e^{\left (-3 \, d x - 3 \, c\right )} + 3 \, e^{\left (-4 \, d x - 4 \, c\right )} + 4}{{\left (a e^{\left (-d x - c\right )} - 2 i \, a e^{\left (-2 \, d x - 2 \, c\right )} - 2 \, a e^{\left (-3 \, d x - 3 \, c\right )} + i \, a e^{\left (-4 \, d x - 4 \, c\right )} + a e^{\left (-5 \, d x - 5 \, c\right )} + i \, a\right )} d} + \frac {3 \, \log \left (e^{\left (-d x - c\right )} + 1\right )}{2 \, a d} - \frac {3 \, \log \left (e^{\left (-d x - c\right )} - 1\right )}{2 \, a d} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [B] Both result and optimal contain complex but leaf count of result is larger than twice
the leaf count of optimal. 234 vs. \(2 (79) = 158\).
time = 0.39, size = 234, normalized size = 2.69 \begin {gather*} \frac {3 \, {\left (e^{\left (5 \, d x + 5 \, c\right )} - i \, e^{\left (4 \, d x + 4 \, c\right )} - 2 \, e^{\left (3 \, d x + 3 \, c\right )} + 2 i \, e^{\left (2 \, d x + 2 \, c\right )} + e^{\left (d x + c\right )} - i\right )} \log \left (e^{\left (d x + c\right )} + 1\right ) - 3 \, {\left (e^{\left (5 \, d x + 5 \, c\right )} - i \, e^{\left (4 \, d x + 4 \, c\right )} - 2 \, e^{\left (3 \, d x + 3 \, c\right )} + 2 i \, e^{\left (2 \, d x + 2 \, c\right )} + e^{\left (d x + c\right )} - i\right )} \log \left (e^{\left (d x + c\right )} - 1\right ) - 6 \, e^{\left (4 \, d x + 4 \, c\right )} + 6 i \, e^{\left (3 \, d x + 3 \, c\right )} + 10 \, e^{\left (2 \, d x + 2 \, c\right )} - 2 i \, e^{\left (d x + c\right )} - 8}{2 \, {\left (a d e^{\left (5 \, d x + 5 \, c\right )} - i \, a d e^{\left (4 \, d x + 4 \, c\right )} - 2 \, a d e^{\left (3 \, d x + 3 \, c\right )} + 2 i \, a d e^{\left (2 \, d x + 2 \, c\right )} + a d e^{\left (d x + c\right )} - i \, a d\right )}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} - \frac {i \int \frac {\operatorname {csch}^{3}{\left (c + d x \right )}}{\sinh {\left (c + d x \right )} - i}\, dx}{a} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A]
time = 0.42, size = 97, normalized size = 1.11 \begin {gather*} \frac {\frac {3 \, \log \left (e^{\left (d x + c\right )} + 1\right )}{a} - \frac {3 \, \log \left (e^{\left (d x + c\right )} - 1\right )}{a} - \frac {2 \, {\left (e^{\left (3 \, d x + 3 \, c\right )} - 2 i \, e^{\left (2 \, d x + 2 \, c\right )} + e^{\left (d x + c\right )} + 2 i\right )}}{a {\left (e^{\left (2 \, d x + 2 \, c\right )} - 1\right )}^{2}} - \frac {4 i}{a {\left (i \, e^{\left (d x + c\right )} + 1\right )}}}{2 \, d} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [B]
time = 0.61, size = 132, normalized size = 1.52 \begin {gather*} \frac {3\,\mathrm {atan}\left (\frac {{\mathrm {e}}^{d\,x}\,{\mathrm {e}}^c\,\sqrt {-a^2\,d^2}}{a\,d}\right )}{\sqrt {-a^2\,d^2}}-\frac {2}{a\,d\,\left ({\mathrm {e}}^{c+d\,x}-\mathrm {i}\right )}-\frac {{\mathrm {e}}^{c+d\,x}}{a\,d\,\left ({\mathrm {e}}^{2\,c+2\,d\,x}-1\right )}-\frac {2\,{\mathrm {e}}^{c+d\,x}}{a\,d\,{\left ({\mathrm {e}}^{2\,c+2\,d\,x}-1\right )}^2}+\frac {2{}\mathrm {i}}{a\,d\,\left ({\mathrm {e}}^{2\,c+2\,d\,x}-1\right )} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________